<ResourceDictionary
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:conv="clr-namespace:QuickZip.Converters"            
    xmlns:local="clr-namespace:QuickZip.UserControls"            
    >
    <ResourceDictionary.MergedDictionaries>
        <ResourceDictionary Source="pack://application:,,,/QuickZip.UserControls;component/Themes/Converters.xaml" />
    </ResourceDictionary.MergedDictionaries>
  
    <Style x:Key="{x:Type local:EditBox}"                       
           TargetType="{x:Type local:EditBox}" >
        <Setter Property="HorizontalAlignment" Value="Left"  />        
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="{x:Type local:EditBox}">
                    <TextBlock x:Name="PART_DisplayTextBlockPart" 
                               Background="{Binding Background, RelativeSource = {RelativeSource FindAncestor,AncestorType={x:Type local:EditBox}}}"
                               Visibility="{Binding IsEditing, Converter={StaticResource fbtv}, RelativeSource = {RelativeSource TemplatedParent}}"  
                               TextWrapping="Wrap" TextAlignment="Center" 
                     Text="{Binding Path=DisplayValue, RelativeSource = {RelativeSource TemplatedParent}}">
                    </TextBlock>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

</ResourceDictionary>
